package entity

import (
	"shqsoft.cn/pasnj/base"
)

//BaseEvaCalc 科目
type BaseEvaCalc struct {
	ID     int     `gorm:"AUTO_INCREMENT;primary_key;column:ID"`
	JJZBZY float64 `gorm:"column:JJZBZY;"`
	JJZBCB float64 `gorm:"column:JJZBCB;"`
	EVA    float64 `gorm:"column:EVA;"`
}

//TableName BaseEvaCalc 机构表名
func (BaseEvaCalc) TableName() string {
	return "T_BASE_EVA_CALC"
}

func (u *BaseEvaCalc) AfterFind() (err error) {
	base.DB.Exec("truncate table T_BASE_EVA_CALC ")
	return nil
}

func BaseEvaCalcEF() base.EntityFunc {
	return func() interface{} {
		entity := BaseEvaCalc{}
		return &entity
	}
}
func BaseEvaCalcESF() base.EntitiesFunc {
	return func() interface{} {
		var entities []BaseEvaCalc
		return &entities
	}
}

func init() {
	base.DaoPoolObj.Put("BaseEvaCalc", base.NewDefaultDao(BaseEvaCalcEF(), BaseEvaCalcESF(), nil))
}
